package org.itboys.mobile.dto.order;

import org.itboys.mobile.dto.common.MobileBaseDto;

import java.math.BigDecimal;
import java.util.List;

/**
 * 作者：jiangxiong
 * 日期：2016年11月25日
 * 联系方式 ：empty90911@126.com
 * 描述：农厨_订单_商品_DTO
 */
public class CooOrderDto extends MobileBaseDto {
     //基础信息
    private String orderNo;//订单编号
    private Integer type;//1，商城，2积分,3采购
    private BigDecimal totalAmount;//订单金额应付(钱或积分)
    private BigDecimal payAmount;//订单金额实付(钱或积分)
    //private Integer payType;//付款方式。1，支付包，2微信
    private String payNo;//付款流水号
    private Integer orderStatus;//订单状态
    private String receiveName;//收货人
    private String receiveMobile;//收货电话
    private String receiveAddress;//收货地址

 //其他属性
    private BigDecimal sendAmount;//配送费
    private String remark;//订单备注


    //时间信息
    private String payTime;//付款时间
    private String sendTime;//配送时间
    private String receiveTime;//收货时间
    private BigDecimal productPrice;//宴会价格
    private String productName;//宴会名称
    private Integer productNum;//宴会数量
    private List<CooOrderProductDto> products;

    public CooOrderDto() {

    }

    public CooOrderDto(long id, String createTime, String createDate, String orderNo, Integer type,
                       BigDecimal totalAmount, BigDecimal payAmount, String payNo, Integer orderStatus,
                       String receiveName, String receiveMobile, String receiveAddress,
                       BigDecimal sendAmount, String remark,
                       String payTime, String sendTime, String receiveTime, List<CooOrderProductDto> products) {
        super(id, createTime, createDate);
        this.orderNo = orderNo;
        this.type = type;
        this.totalAmount = totalAmount;
        this.payAmount = payAmount;
        this.payNo = payNo;
        this.orderStatus = orderStatus;
        this.receiveName = receiveName;
        this.receiveMobile = receiveMobile;
        this.receiveAddress = receiveAddress;
        this.sendAmount = sendAmount;
        this.remark = remark;
        this.payTime = payTime;
        this.sendTime = sendTime;
        this.receiveTime = receiveTime;
        this.products = products;
    }
    public String getOrderNo() {
        return orderNo;
    }

    public void setOrderNo(String orderNo) {
        this.orderNo = orderNo;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public BigDecimal getTotalAmount() {
        return totalAmount;
    }

    public void setTotalAmount(BigDecimal totalAmount) {
        this.totalAmount = totalAmount;
    }

    public BigDecimal getPayAmount() {
        return payAmount;
    }

    public void setPayAmount(BigDecimal payAmount) {
        this.payAmount = payAmount;
    }

    public String getPayNo() {
        return payNo;
    }

    public void setPayNo(String payNo) {
        this.payNo = payNo;
    }

    public Integer getOrderStatus() {
        return orderStatus;
    }

    public void setOrderStatus(Integer orderStatus) {
        this.orderStatus = orderStatus;
    }

    public String getReceiveName() {
        return receiveName;
    }

    public void setReceiveName(String receiveName) {
        this.receiveName = receiveName;
    }

    public String getReceiveMobile() {
        return receiveMobile;
    }

    public void setReceiveMobile(String receiveMobile) {
        this.receiveMobile = receiveMobile;
    }

    public String getReceiveAddress() {
        return receiveAddress;
    }

    public void setReceiveAddress(String receiveAddress) {
        this.receiveAddress = receiveAddress;
    }


    public BigDecimal getSendAmount() {
        return sendAmount;
    }

    public void setSendAmount(BigDecimal sendAmount) {
        this.sendAmount = sendAmount;
    }


    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }


    public String getPayTime() {
        return payTime;
    }

    public void setPayTime(String payTime) {
        this.payTime = payTime;
    }

    public String getSendTime() {
        return sendTime;
    }

    public void setSendTime(String sendTime) {
        this.sendTime = sendTime;
    }

    public String getReceiveTime() {
        return receiveTime;
    }

    public void setReceiveTime(String receiveTime) {
        this.receiveTime = receiveTime;
    }

    public List<CooOrderProductDto> getProducts() {
        return products;
    }

    public void setProducts(List<CooOrderProductDto> products) {
        this.products = products;
    }

    public BigDecimal getProductPrice() {
        return productPrice;
    }

    public void setProductPrice(BigDecimal productPrice) {
        this.productPrice = productPrice;
    }

    public String getProductName() {
        return productName;
    }

    public void setProductName(String productName) {
        this.productName = productName;
    }

    public Integer getProductNum() {
        return productNum;
    }

    public void setProductNum(Integer productNum) {
        this.productNum = productNum;
    }

    /**
     * 状态的中文信息
     */
    public String  getTypeStr(){
        String typeStr= "";
        if(type==null)return typeStr;

        switch (type) {
            case 1:
                typeStr="商城订单";
                break;
            case 2:
                typeStr="积分订单";
                break;
            case 3:
                typeStr="采购订单";
                break;
            default:
                break;
        }
        return typeStr;
    }

    public String  getOrderStatusStr(){
        String orderStatusStr= "";
        if(orderStatus==null)return orderStatusStr;

        switch (orderStatus) {
            case 1:
                orderStatusStr="待付款";
                break;
            case 2:
                orderStatusStr="待配送";
                break;
            case 3:
                    orderStatusStr="配送中";
                break;
            case 4:
                orderStatusStr="待评价";
                break;
            case 5:
                orderStatusStr="已评价";
                break;
            case 6:
                orderStatusStr="待退款";
                break;
            case 7:
                orderStatusStr="已退款";
                break;
            case 8:
                orderStatusStr="待退货";
                break;
            case 9:
                orderStatusStr="已退货";
                break;
            case 10:
                orderStatusStr="已取消";
                break;
            default:
                break;
        }
        return orderStatusStr;
    }
/*    public String  getSendTypeStr(){
        String sendTypeStr= "";
        if(sendType==null)return sendTypeStr;

        switch (sendType) {
            case 1:
                sendTypeStr="门店配送";
                break;
            case 2:
                sendTypeStr="自提";
                break;
            case 3:
                sendTypeStr="其他";
                break;
            default:
                break;
        }
        return sendTypeStr;
    }*/

}


